package bean;

/**
 * A base class for Media for manipulation of the data
 * @author Anne Lorayne, Laura Dutra, Otavio Lima
 *
 */
public class MediaBean {

	private String ID;
	 
	private String URL;
	
	private String description;
	 
	/**
	 * Constructor of the class
	 * @param ID
	 * @param URL
	 */
	public MediaBean(String ID, String URL, String description){
		this.ID = ID;
		this.URL = URL;
		this.description = description;
	}
	
	public MediaBean(){}
	
	// ------Getters and Setters------
	
	public String getID() {
		return ID;
	}

	public void setID(String iD) {
		ID = iD;
	}

	public String getURL() {
		return URL;
	}

	public void setURL(String URL) {
		this.URL = URL;
	}
	
	 
	/**
	 * @return the description
	 */
	public String getDescription() {
		return description;
	}

	/**
	 * @param description the description to set
	 */
	public void setDescription(String description) {
		this.description = description;
	}
	
	/* (non-Javadoc)
	 * @see java.lang.Object#equals(java.lang.Object)
	 */
	@Override
	public boolean equals(Object obj) {
		if (this == obj)
			return true;
		if (obj == null)
			return false;
		if (!(obj instanceof MediaBean))
			return false;
		MediaBean other = (MediaBean) obj;
		if (ID == null) {
			if (other.ID != null)
				return false;
		} else if (!ID.equals(other.ID))
			return false;
		if (URL == null) {
			if (other.URL != null)
				return false;
		} else if (!URL.equals(other.URL))
			return false;
		return true;
	}

	
	
	
}
 
